Type checking a multithreaded functional language with session types
نویسندگان
چکیده
We define a language whose type system, incorporating session types, allows com-plex protocols to be specified by types and verified by static typechecking. A ses-sion type, associated with a communication channel, specifies the state transitionsof a protocol and also the data types of messages associated with transitions; thustypechecking can verify both correctness of individual messages and correctness ofsequences of transitions. Previously, session types have mainly been studied in thecontext of the π-calculus; instead, our formulation is based on a multi-threaded func-tional language with side-effecting input/output operations. Our typing judgementsstatically describe dynamic changes in the types of channels, and our function typesnot only specify argument and result types but also describe changes in channels.We formalize the syntax, semantics and type checking system of our language, andprove subject reduction and runtime type safety theorems.
منابع مشابه
Asynchronous Functional Session Types
Session types support a type-theoretic formulation of structured patterns of communication, so that the communication behaviour of agents in a distributed system can be verified by static type checking. Applications include network protocols, business processes, and operating system services. In this paper we define a multithreaded functional language with session types, which unifies, simplifi...
متن کاملLinear type theory for asynchronous session types
Session types support a type-theoretic formulation of structured patterns of communication, so that the communication behaviour of agents in a distributed system can be verified by static type checking. Applications include network protocols, business processes, and operating system services. In this paper we define a multithreaded functional language with session types, which unifies, simplifi...
متن کاملStatic Checking for Multiple Start of Threads in a Type-Safe Multithreaded Java
We present MTMJ, a multithreaded middleweight model language for Java which is strongly typed and prevents multiple run-time start of threads. The key point in designing the language is to balance precision and efficiency by judicious utilization of context information during type checking. While the types are flow-insensitive, the required flowdependent information is collected as type checkin...
متن کاملType-safe Communication in Java with Session Types
This paper demonstrates the impact of integrating session types for communication behaviour into object-oriented languages, through their implementation in a distributed Java. Session types abstract a potentially unbounded structured sequence of communications in an easy-to-read type syntax, and guarantee the absence of communication errors through static type-checking. The introduction of sess...
متن کاملModular Session Types for Objects
Session types allow communication protocols to be specified type-theoretically so that protocol implementations can be verified by static type checking. We extend previous work on session types for distributed object-oriented languages in three ways. (1) We attach a session type to a class definition, to specify the possible sequences of method calls. (2) We allow a session type (protocol) impl...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید
ثبت ناماگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید
ورودعنوان ژورنال:
- Theor. Comput. Sci.
دوره 368 شماره
صفحات -
تاریخ انتشار 2006